package com.ruoyi.erp.service.impl;

import java.util.List;
import com.ruoyi.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.erp.mapper.BzFaCardsDelMapper;
import com.ruoyi.erp.domain.BzFaCardsDel;
import com.ruoyi.erp.service.IBzFaCardsDelService;

/**
 * 资产减少Service业务层处理
 * 
 * @author ztj
 * @date 2023-04-19
 */
@Service
public class BzFaCardsDelServiceImpl implements IBzFaCardsDelService 
{
    @Autowired
    private BzFaCardsDelMapper bzFaCardsDelMapper;

    /**
     * 查询资产减少
     * 
     * @param id 资产减少主键
     * @return 资产减少
     */
    @Override
    public BzFaCardsDel selectBzFaCardsDelById(Long id)
    {
        return bzFaCardsDelMapper.selectBzFaCardsDelById(id);
    }
    @Override
    public List<BzFaCardsDel> selectBzFaCardsDelByIds(Long[] id)
    {
        return bzFaCardsDelMapper.selectBzFaCardsDelByIds(id);
    }

    /**
     * 查询资产减少列表
     * 
     * @param bzFaCardsDel 资产减少
     * @return 资产减少
     */
    @Override
    public List<BzFaCardsDel> selectBzFaCardsDelList(BzFaCardsDel bzFaCardsDel)
    {
        return bzFaCardsDelMapper.selectBzFaCardsDelList(bzFaCardsDel);
    }

    /**
     * 新增资产减少
     * 
     * @param bzFaCardsDel 资产减少
     * @return 结果
     */
    @Override
    public int insertBzFaCardsDel(BzFaCardsDel bzFaCardsDel)
    {
        bzFaCardsDel.setCreateTime(DateUtils.getNowDate());
        return bzFaCardsDelMapper.insertBzFaCardsDel(bzFaCardsDel);
    }

    /**
     * 修改资产减少
     * 
     * @param bzFaCardsDel 资产减少
     * @return 结果
     */
    @Override
    public int updateBzFaCardsDel(BzFaCardsDel bzFaCardsDel)
    {
        bzFaCardsDel.setUpdateTime(DateUtils.getNowDate());
        return bzFaCardsDelMapper.updateBzFaCardsDel(bzFaCardsDel);
    }
    @Override
    public int updateBzFaCardsDelIds(Long[] ids)
    {
        return bzFaCardsDelMapper.updateBzFaCardsDelIds(ids);
    }

    @Override
    public int updateBzFaCardsDelIdsFail(Long[] ids)
    {
        return bzFaCardsDelMapper.updateBzFaCardsDelIdsFail(ids);
    }
    /**
     * 批量删除资产减少
     * 
     * @param ids 需要删除的资产减少主键
     * @return 结果
     */
    @Override
    public int deleteBzFaCardsDelByIds(Long[] ids)
    {
        return bzFaCardsDelMapper.deleteBzFaCardsDelByIds(ids);
    }

    /**
     * 删除资产减少信息
     * 
     * @param id 资产减少主键
     * @return 结果
     */
    @Override
    public int deleteBzFaCardsDelById(Long id)
    {
        return bzFaCardsDelMapper.deleteBzFaCardsDelById(id);
    }
}
